package com.nd.qa.shareplate.common;

/**
 * <p>定义公共信息类</p>
 * @author 黄坚
 * @createDate 2015-08-31 下午 17:46:46
 * @version V1.0
 */
public class SysConstant {

	//session定义
	public static final String SESSION_KEY_LOGIN_USER = "session_key_login_user";
	
	public static final String SESSION_KEY_TERMINAL_TYPE = "SESSION_KEY_TERMINAL_TYPE";
	
	/**
	 * 项目进度状态: 1000创建完成（初始状态）  1001项目创建失败；1002脚本生成成功  1003脚本生成失败  1004提交测试中  1005测试完成 1006测试异常
	 */
	
	public static final String PROJECT_STATUS_CREATE_SUCCESS="1000";
	
	public static final String PROJECT_STATUS_CREATE_FAIL="1001";
	
	public static final String PROJECT_STATUS_SCRIPT_READY="1002";
	
	public static final String PROJECT_STATUS_SCRIPT_FAIL="1003";
	
	public static final String PROJECT_STATUS_JOIN_TEST_QUEUE= "1004";
	
	public static final String PROJECT_STATUS_TEST_FINISH="1005";
	
	public static final String PROJECT_STATUS_PROCESS_ERROR="1006";	
	
	public static final String OPERATOR_TYPE_PAGE_LOG="100";
	
	public static final String OPERATOR_TYPE_ELEMENT_LOG="101";
	
	public static final String OPERATOR_ACTION_ADD_LOG="ADD";
	
	public static final String OPERATOR_ACTION_UPDATE_LOG="UPDATE";
	
	public static final String OPERATOR_ACTION_DEL_LOG="DEL";
	/**
	 * 分页默认展示每页的记录数
	 */
	public static final Integer PAGE_RECORD_COUNT = 5;	
	
	
	
	public static final String rootPath = "D:/CICODE/CISCRIPT/";
	
	public static final String localLoadPath = "E:/UIServer/shareplate/resources/file/upload-apk/";//"D:/ndworkspaces/webworkspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/shareplate/resources/file/upload-apk/";
	
	public static final String sharePlateApkPath = "E:/UIServer/apache-sharepalte/webapps/shareplate/resources/file/upload-apk/";
	
	public static final String localApkPath = "http://192.168.239.106:8082/shareplate/resources/file/upload-apk/";
	
	/*public static final String rootPath = "/home/perfor/shareplate/scripts/";

	public static final String localLoadPath = "/home/perfor/shareplate/upload-apk/";//"D:/ndworkspaces/webworkspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/shareplate/resources/file/upload-apk/";
	
	public static final String sharePlateApkPath = "/home/perfor/tomcat-shareplate/webapps/shareplate/resources/file/upload-apk/";
	
	public static final String localApkPath = "http://192.168.239.136:8082/shareplate/resources/file/upload-apk/";*/
	
	public static final String scriptPath = "/resources/file/script-build/";
	public static final String reportPath = "/resources/file/script-report/";
	public static final String testPath = "/resources/file/test-apk/";
	/**
	 * 项目脚本执行的方式
	 */
	/**
	 * realmonkey方式测试
	 */
	public static final int REALMONKEY = 0;
	/**
	 * robotium方式测试
	 */
	public static final int ROBOTIUM = 1;
	/**
	 * appium方式测试
	 */
	public static final int APPIUM = 2;
	/**
	 * macaca方式测试
	 */
	public static final int MACACA = 3;
	/**
	 * selenium方式测试
	 */
	public static final int SELENIUM = 4;
	/**
	 * 元素类型
	 */
	public static final String ELEMENT_TYPE_TEXT = "Text";
	public static final String ELEMENT_TYPE_TEXTVIEW = "TextView";
	public static final String ELEMENT_TYPE_ID = "ID";
	public static final String ELEMENT_TYPE_NAME = "NAME";
	public static final String ELEMENT_TYPE_ACCESSIBILITYID = "AccessibilityId";
	public static final String ELEMENT_TYPE_XPATH = "XPATH";
	public static final String ELEMENT_TYPE_TAGNAME = "TAG_NAME";
	public static final String ELEMENT_TYPE_CLASSNAME = "CLASS_NAME";
	public static final String ELEMENT_TYPE_CSSSELECTOR = "CSS";
	public static final String ELEMENT_TYPE_LINKTEXT = "LINK_TEXT";
	public static final String ELEMENT_TYPE_EDITTEXT = "EditText";
	public static final String ELEMENT_TYPE_BUTTON = "Button";
	public static final String ELEMENT_TYPE_IMAGEBUTTON = "ImageButton";
	public static final String ELEMENT_TYPE_IMAGEVIEW = "ImageView";
	public static final String ELEMENT_TYPE_KEYBOARD = "KeyBoard";
	
	/**
	 * 元素操作类型
	 */
	public static final String ACTION_DRAG_LEFT = "drag-left";
	public static final String ACTION_DRAG_RIGHT = "drag-right";
	public static final String ACTION_DRAG_UP = "drag-up";
	public static final String ACTION_DRAG_DOWN = "drag-down";
	

	/**
	 * 上滑查询名称
	 */
	public static final String SCROLLUPQUERYBYNAME = "scrollUpQueryByName";
	/**
	 * 上滑查询id
	 */
	public static final String SCROLLUPQUERYBYID = "scrollUpQueryById";
	/**
	 * 下滑查询名称
	 */
	public static final String SCROLLDOWNQUERYBYNAME = "scrollDownQueryByName";
	/**
	 * 下滑查询id
	 */
	public static final String SCROLLDOWNQUERYBYID = "scrollDownQueryById";
	/**
	 * 上滑（中间位置）
	 */
	public static final String SCROLLTOUP = "scrollToUp";
	/**
	 * 上滑（页面位置左边 ）
	 */
	public static final String SCROLLTOUPONLEFT = "scrollToUpOnLeft";
	/**
	 * 上滑（页面位置右边 ）
	 */
	public static final String SCROLLTOUPONRIGHT = "scrollToUpOnRight";
	/**
	 * 下滑
	 */
	public static final String SCROLLTODOWN = "scrollToDown";
	/**
	 * 左滑
	 */
	public static final String SCROLLTOLEFT = "scrollToLeft";
	/**
	 * 中间位置左滑
	 */
	public static final String SCROLLTOLEFTONCENTER = "scrollToLeftOnCenter";
	/**
	 * 底部左滑
	 */
	public static final String SCROLLTOLEFTONBOTTOM = "scrollToLeftOnBottom";
	
	
	/**
	 * 测试流程标识
	 */
	//流程开始
    public static final Integer PROCESS_STATUS_START=0;
    //开始同步资源
    //public static final Integer PROCESS_STATUS_SYNC_START=1;
    //同步资源完成
    public static final Integer PROCESS_STATUS_SYNC_END=2;
    //开始调用测试脚本
    public static final Integer PROCESS_STATUS_TEST_START=1;
    //脚本执行结束
    public static final Integer PROCESS_STATUS_TEST_END=2;
    //开始推送测试报告
    //public static final Integer PROCESS_STATUS_PUSH_REPORT_START=3;
    //推送测试报告完成
    //public static final Integer PROCESS_STATUS_PUSH_REPORT_END=4;
    //开始推送门户通知
   // public static final Integer PROCESS_STATUS_PUSH_MSG_START=5;
    //推送完成 - 流程结束
    //public static final Integer PROCESS_STATUS_PUSH_MSG_END=6;
    
    public static final String SOURCE_BASE_PATH = "E:/Sources/Test/";
    /**
     * 测试报告地址
     */
    public static final String LOCAL_REPORT_DEPTH="D:\\CICODE\\CISCRIPTS\\";
    /**
     * 接口地址
     */
    //用户注册接口
    public static final String REGISTERUSER_URL = "http://192.168.239.106:8082/shareplate/user/registerUser";
    //查询用户信息接口
    public static final String QUERYBYUSERNAME_URL = "http://192.168.239.106:8082/shareplate/user/queryByUserName";
    //查询项目类型接口
    public static final String QUERYINFOBYTYPE_URL = "http://192.168.239.106:8082/shareplate/project/queryInfoByType";
    //查询项目类型中最新版本的脚本
    public static final String QUERYLATESTSCRIPTBYUSERID_URL = "http://192.168.239.106:8082/shareplate/project/queryLatestScriptByUserId";
    //录入任务信息接口
    public static final String INSERTPROJECTINFO_URL = "http://192.168.239.106:8082/shareplate/project/insertProjectInfo";
    //查询项目id接口
    public static final String QUERYPROJECTSEQBYNAME_URL = "http://192.168.239.106:8082/shareplate/project/queryProjectSeqByName";
    //录入99u推送的消息
    public static final String INSERTMESSAGE_URL = "http://192.168.239.106:8082/shareplate/project/insertMessage";
    //查询99u推送的消息
    public static final String QUERYMSGINFO_URL = "http://192.168.239.106:8082/shareplate/project/queryMsgInfo";
    //添加日志信息接口
    public static final String ADDLOG_URL = "http://192.168.239.106:8082/shareplate/project/addLog";
    
    /**
     * uc接口测试Jenkins地址
     */
    public static final String UC_INTERFACE_URL = "http://192.168.239.127:8000/job/SharedPlatform.portal_101_account_api_product/build";
}
